package com.zerui.manager.device.domainservice;

import com.zerui.manager.device.Device;
import com.zerui.manager.device.custom.DeviceCustom;
import com.zerui.manager.device.gateway.DeviceGateWay;
import org.springframework.stereotype.Component;
import javax.annotation.Resource;
import java.util.List;
import java.util.Set;
/**
 * @Author wh
 * @create_time 2023-08-23 11:07
 */
@Component
public class DeviceRepository {

    @Resource
    private DeviceGateWay deviceGateWay;

    public List<Device> selectByDeviceIds(Set<Long> deviceIds) {
        return deviceGateWay.selectByDeviceIds(deviceIds);
    }

    public List<DeviceCustom> selectByDeviceIds2(Set<Long> deviceIds) {
        return deviceGateWay.selectByDeviceIds2(deviceIds);
    }

    public Device getByDeviceId(Long id) {
        return deviceGateWay.getByDeviceId(id);
    }

    public void update(Device device) {
        deviceGateWay.update(device);
    }

    public void add(Device device) {
        deviceGateWay.add(device);
    }

    public void deleteById(Long deviceId) {
        deviceGateWay.deleteById(deviceId);
    }

	public void updateByDeviceId(Device device) {
		deviceGateWay.updateByDeviceId(device);
	}


}
